home *** CD-ROM | disk | FTP | other *** search
/ BCI NET / BCI NET Dec 94.iso / archives / programming / blitzbasic / blitz-list200994.lha / blitz-list / text0193.txt < prev    next >
Encoding:
Text File  |  1994-09-20  |  597 b   |  23 lines

  1.  
  2. hi there,
  3.  
  4.         just seen swapping routine in a PC Visual Basic manual at work and
  5. wondered if anyone else knew of the routine.....
  6.  
  7. NORMAL SWAP                             Cool Swap
  8. -----------                             ---------
  9.  
  10.         temp = a                        a = a xor b
  11.         b = a                           b = b xor a
  12.         a = temp                        a = a xor b
  13.  
  14.  
  15. This new routine actually gets rid of the 3rd variable and 'could' reduce
  16. the processing time?? I problem is is that it can only work on numbers NOT
  17. strings - or could it? - who knows, who cares!
  18.  
  19.  
  20.  
  21.  
  22.  
  23.